Support revised documents/collections in Jekyll 3 (v2)#53
Conversation
Signed-off-by: Alfred Xing <alfredxing@users.noreply.github.com>
Signed-off-by: Alfred Xing <alfredxing@users.noreply.github.com>
|
@alfredxing Not a problem! Learnt a few things while making the changes too, which is no bad thing 😀 |
lib/jekyll-archives.rb
Outdated
There was a problem hiding this comment.
We were doing a version check Jekyll::VERSION < '3.0.0' to determine if it should be treated as an array or not. What do you think about each approach? I'm not sure which I like better.
There was a problem hiding this comment.
@paulrobertlloyd Mentioned that this is technically 'safer', but I think checking the version is more understandable....
There was a problem hiding this comment.
I only did it this way because I didn’t know how to test for the version number! Agree that using version number is cleaner and more understandable. Happy for this test to be changed to that.
There was a problem hiding this comment.
I'll make the quick fix & merge!
@parkr It works! I think originally I wasn't too sure because this now uses the site's posts object instead of ours, but they should be the same anyways.
@paulrobertlloyd I've kept your commits in here since we do still need the checks when constructing the archives by year. Thanks for your work on this!